home *** CD-ROM | disk | FTP | other *** search
/ Aminet 5 / Aminet 5 - March 1995.iso / Aminet / util / rexx / xdmd1.lha / RepReq.xdme < prev    next >
Text File  |  1994-10-26  |  739b  |  24 lines

  1. /* RepReq.xdme */
  2.  
  3. if ~show("L","rexxreqtools.library") then
  4.     if ~addlib("rexxreqtools.library", 0, -30) then exit
  5.  
  6. if ~show("L","rexxarplib.library") then
  7.     if ~addlib("rexxarplib.library",0,-30,0) then exit
  8.  
  9. F = '(' || GetEnv('F') || ')'
  10. R = rtgetstring(GetEnv('R'),"Enter Replace String","XDMD Replace Requester","_Here|_All|_Block|_Cancel")
  11. if rtresult = 0 then exit
  12. R = '(' || R || ')'
  13. xcom = 'setenv R' R 'repstr' R 'setenv F' F 'findstr' F
  14. xcom
  15. if rtresult = 1 then do
  16.     'scanf w setenv F $scanf findstr $F replace'
  17. end
  18. else if rtresult = 2 then do
  19.     'bottom last repeat -1 (prev push pos replace pop pos)'
  20. end
  21. else do
  22.     'goto end right ifelse cb last left while cb (prev if cb (push pos replace pop pos) goto block'
  23. end
  24.